package com.centriole.service.workflow.entity;

import java.util.HashMap;
import java.util.Map;

/**
 * v2: 2018/1/4 添加了 3个字段(allowStop、allowRecall、allowHang)描述了 是否能操作任务进度
 * v3: 2018/1/10 添加了taskType字段
 */
public class TaskModel {

	private String taskId;
	private String taskName;
	private String instanceId;
	private String businessKey;
	private String startUser;
	private String processName;
	private String flowRemark;
	private String startTime;
	private Map<String,Object> variables;
	private String viewPageUrl;
	private String completeUser;
	private String lastCompleteTime;
	private String completeRemark;
	private String proState;
	//v2:新添加的字段
	private String allowStop;			//是否允许 当前任务终止
	private String allowRecall;		//是否允许 当前任务能够被上部回撤
	private String allowHang;			//是否允许 当前任务被挂起
	//v3:添加taskType字段
	private String taskType;			//任务类型:普通单任务、审批任务
	//v4:添加taskNodeId
	private String nodeId;				//任务节点Id
	private String taskLogicalName;
	
	public String getProState() {
		return proState;
	}
	public void setProState(String proState) {
		this.proState = proState;
	}
	public String getTaskId() {
		return taskId;
	}
	public void setTaskId(String taskId) {
		this.taskId = taskId;
	}
	public String getTaskName() {
		return taskName;
	}
	public void setTaskName(String taskName) {
		this.taskName = taskName;
	}
	public String getInstanceId() {
		return instanceId;
	}
	public void setInstanceId(String instanceId) {
		this.instanceId = instanceId;
	}
	public String getBusinessKey() {
		return businessKey;
	}
	public void setBusinessKey(String businessKey) {
		this.businessKey = businessKey;
	}
	public String getStartUser() {
		return startUser;
	}
	public void setStartUser(String startUser) {
		this.startUser = startUser;
	}
	public String getProcessName() {
		return processName;
	}
	public void setProcessName(String processName) {
		this.processName = processName;
	}
	public String getFlowRemark() {
		return flowRemark;
	}
	public void setFlowRemark(String flowRemark) {
		this.flowRemark = flowRemark;
	}
	public String getStartTime() {
		return startTime;
	}
	public void setStartTime(String startTime) {
		this.startTime = startTime;
	}
	public Map<String, Object> getVariables() {
		if(null != variables)
			return variables;
		return new HashMap<>();
	}
	public void setVariables(Map<String, Object> variables) {
		this.variables = variables;
	}
	public String getViewPageUrl() {
		return viewPageUrl;
	}
	public void setViewPageUrl(String viewPageUrl) {
		this.viewPageUrl = viewPageUrl;
	}
	public String getCompleteUser() {
		return completeUser;
	}
	public void setCompleteUser(String completeUser) {
		this.completeUser = completeUser;
	}
	public String getLastCompleteTime() {
		return lastCompleteTime;
	}
	public void setLastCompleteTime(String lastCompleteTime) {
		this.lastCompleteTime = lastCompleteTime;
	}
	public String getCompleteRemark() {
		return completeRemark;
	}
	public void setCompleteRemark(String completeRemark) {
		this.completeRemark = completeRemark;
	}
	
	//v2: getter and setter
	public String getAllowStop() {
		return allowStop;
	}
	public void setAllowStop(String allowStop) {
		this.allowStop = allowStop;
	}
	public String getAllowRecall() {
		return allowRecall;
	}
	public void setAllowRecall(String allowRecall) {
		this.allowRecall = allowRecall;
	}
	public String getAllowHang() {
		return allowHang;
	}
	public void setAllowHang(String allowHang) {
		this.allowHang = allowHang;
	}
	
	public String getTaskType() {
		return taskType;
	}
	public void setTaskType(String taskType) {
		this.taskType = taskType;
	}
	
	
	public String getNodeId() {
		return nodeId;
	}
	public void setNodeId(String nodeId) {
		this.nodeId = nodeId;
	}
	@Override
	public String toString() {
		return "TaskModel [taskId=" + taskId + ", processName=" + processName + ", allowStop=" + allowStop + ", allowRecall=" + allowRecall + ", allowHang=" + allowHang + "]";
	}
	public String getTaskLogicalName() {
		return taskLogicalName;
	}
	public void setTaskLogicalName(String taskLogicalName) {
		this.taskLogicalName = taskLogicalName;
	}

	
	
	
	
}
